dhcpv6: support a configurable DUID
authorDavid Härdeman <[email protected]>
Fri, 10 Oct 2025 07:38:38 +0000 (09:38 +0200)
committerÁlvaro Fernández Rojas <[email protected]>
Sun, 26 Oct 2025 21:29:45 +0000 (22:29 +0100)
commitfc27940fe9939f99aeb988d021c7edfa54460123
treec9603caf00eb9928cb034d7ed843110207f3836c
parentae16476bcad27049f82e3043e88958405096c4bb
dhcpv6: support a configurable DUID

Allow the use of a (stable) globally configured DUID as the server identifier.

Currently, odhcpd generates a per-interface DUID-LL, meaning that the DUID is
not stable across interfaces and will change if/when hardware changes.

Supporting a stable DUID brings odhcpd's behaviour in line with RFC8415, §11:

                                                      ...The DUID is
   designed to be unique across all DHCP clients and servers, and stable
   for any specific client or server.  That is, the DUID used by a
   client or server SHOULD NOT change over time if at all possible; for
   example, a device's DUID should not change as a result of a change in
   the device's network hardware or changes to virtual interfaces...

Signed-off-by: David Härdeman <[email protected]>
Link: https://github.com/openwrt/odhcpd/pull/274
Signed-off-by: Álvaro Fernández Rojas <[email protected]>
README.md
src/config.c
src/dhcpv6-ia.c
src/dhcpv6.c
src/odhcpd.h